<!--#include file="../nav/admin_top.php" -->
<?PHP $lmenuindex=1;?>
<!--#include file="../nav_menu/source_begin.php" -->


<div id="grids"></div> 
<script type="text/javascript">
var url_list = '/admin_field/index'; 
var url_modify = '/admin_field/modify';
$().ready(function(){
	o2js.build('ymprompt'); 
	o2js.build('o2grid');
	showLoading();
	grids = new o2Grid({
		bind:'grids', 
		url:url_list,
		rowNum:100,
		imgpath:'/misc/vendors/o2js/o2grid/image',
		cols:[
			{index:'name',mapping:'a.name', name:'溯源阶段', width:250,func:function(val,row_index,column_name,json,R){
					return val;
				}
			},
			{index:'field_num',mapping:'a.field_num',align:"center", name:'自定义属性总数', width:250,func:function(val,row_index,column_name,json,R){
					return val;
				}
			},
			{index:'id',mapping:'a.id', name:'操作'	, align:"center",width:250,sortable:false,func:function(val,row_index,column_name,json,R){
					return   ' <a href="javascript:void(0)" onclick="fnMofidy('+json.id+')" >设置自定义属性</a> ';
				}
			}
		]
	});
	grids.load(1);
});   


/* 修改 */
function fnMofidy(id){ 
	ymPrompt.close();
	ymPrompt.win({
		title:'设置自定义属性',
		fixPosition:true,
		maxBtn:true,
		width: 800, 
		height: 500,
		iframe:{
			src:url_modify+'?id='+id
		},
		handler:handlerModify
	});
}
function handlerModify(tp){
	if(tp=='close'){
		grids.load(1);
	}
}
</script>
<!--#include file="../nav_menu/source_end.php" -->
<!--#include file="../nav/admin_bottom.php" -->